/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package mapreduce;

import cfar.ff.fun.F2;
import cfar.ff.interfaces.Monoid;
/**
 *
 * @author haoyun
 */
public class impMono<A> extends Monoid{

    A empt;
    A value;
    F2<A,A,A> fapend;

    impMono (A a, F2 f, A b){
        this.empt=a;
        this.fapend=f;
        this.value=b;
    }


    @Override
    public A empty() {
        return empt;
    }

    @Override
    public F2 append() {
        return fapend;
    }

    @Override
    public A fromMonoid() {
        return value;
    }
    
}
